package com.sxt.controller;

import com.sxt.domain.User;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.ArrayList;
import java.util.List;

@RestController
public class TestController {


    @RequestMapping("/loadOne")
    public User loadOne(){

        return new User("1","111","wwww");

    }


    @RequestMapping("/loadAll")
    public List<User> loadAll(){
        List<User> u = new ArrayList<>();
        for (int i = 1; i < 10; i++) {

            u.add(new User("1"+i,"2"+i,"ww"+i));
        }

        return u;
    }
}
